//#define __DEBUG__
#define THIS_FILE "fn_missilcamrun.sqf"
#include "x_setup.sqf"

private "_oldcam";
_oldcam = KEGs_cameraIdx;
while {!isNull _this && {speed _this > 1} && {_oldcam == KEGs_cameraIdx} && {dialog}} do {
	KEGs_cam_missile camSetTarget _this;
	KEGs_cam_missile camSetRelPos [0, -0.5, 0.30];
	KEGs_cam_missile camCommit 0;
	sleep 0.01;
};
if (_oldcam == KEGs_cameraIdx && {dialog}) then {
	sleep 3;
};
KEGs_MissileCamActive = false;
KEGs_MissileCamOver = true;